package com.ysd.ziyuanshiyongtongji.dao;

import com.ysd.ziyuanshiyongtongji.model.Admin;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

/**
 * IAdminDao
 */
public interface IAdminDao extends JpaRepository<Admin,Integer>,JpaSpecificationExecutor <Admin>{
    @Query(nativeQuery = true,value = "select * from admin a where a.name=?1 and a.pass=?2")
    Admin login(String name,String pass);
}